package com.ysd.lis.controller.lab;


import com.ysd.common.Result;
import com.ysd.lis.controller.pub.BaseController;
import com.ysd.lis.entity.lab.WlConfigPatsetting;
import com.ysd.lis.entity.lab.WlConfigResultssetting;
import com.ysd.lis.request.wl.WlConfigSettingParam;
import com.ysd.lis.service.lab.WlConfigResultssettingService;
import io.swagger.annotations.ApiOperation;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.*;

import java.util.List;

/**
 * <p>
 * 结果列表配置 前端控制器
 * </p>
 *
 * @author WangHao
 * @since 2024-01-18
 */
@RestController
@RequestMapping("/lab/wlConfigResultssetting")
public class WlConfigResultssettingController extends BaseController {

    @Autowired
    private WlConfigResultssettingService wlConfigResultssettingService;

    @ApiOperation("通过配置id获取结果信息")
    @GetMapping("/findResultstingByConfigId")
    public Result findResultstingByConfigId(WlConfigSettingParam wlConfigParam) {
        return wlConfigResultssettingService.findResultstingByConfigId(wlConfigParam);
    }

    @ApiOperation("新增或修改结果信息")
    @PostMapping("/insertOrUpdateResultsting")
    public Result insertOrUpdateResultsting(@RequestBody List<WlConfigResultssetting> wlConfigResultssetting) {
        return wlConfigResultssettingService.insertOrUpdateResultsting(wlConfigResultssetting);
    }
}
